lib/fetcher: Factor out HTTP status code handling from soup and curl
authorPhilip Withnall <withnall@endlessm.com>
Wed, 30 May 2018 11:20:49 +0000 (12:20 +0100)
committerAtomic Bot <atomic-devel@projectatomic.io>
Wed, 30 May 2018 16:23:57 +0000 (16:23 +0000)
commit197644c406deec76a6567e6639ebd6e06dbc1013
tree817a85cc95d9390bf78109abfa5da65e6fbc0b96
parent78f40136dbf8411a66ce3f6d8263d8e72d951163
lib/fetcher: Factor out HTTP status code handling from soup and curl

Use the same G_IO_ERROR_* values for HTTP status codes in both fetchers.
The libsoup fetcher still handles a few more internal error codes than
the libcurl one; this could be built on in future.

Signed-off-by: Philip Withnall <withnall@endlessm.com>
Closes: #1594
Approved by: jlebon
src/libostree/ostree-fetcher-curl.c
src/libostree/ostree-fetcher-soup.c
src/libostree/ostree-fetcher-util.c
src/libostree/ostree-fetcher-util.h